      1  /**

      2      This event describes a customer arriving at a bank.

      3  */

      4  public class Arrival extends Event

      5  {

      6     /**

      7        @param time the arrival time

      8     */

      9     public Arrival(double time) { super(time); }

     10

     11     public void process(Simulation sim)

     12     {

     13        double now = sim.getCurrentTime();

     14        BankSimulation bank = (BankSimulation) sim;

     15        Customer c = new Customer(now);

     16        bank.add(c);

     17     }

     18  }